# Contributor: Anon <danilagdn.2004@gmail.com>
# Maintainer: Lindsay Zhou <i@lin.moe>
pkgname=sing-geoip
pkgver=20240912
pkgrel=0
pkgdesc="sing-geoip database"
_repo="SagerNet/$pkgname"
url="https://github.com/$_repo"
arch="noarch"
license="GPL-3.0-or-later"
source="$pkgver.geoip-cn.db::$url/releases/download/$pkgver/geoip-cn.db
				$pkgver.geoip.db::$url/releases/download/$pkgver/geoip.db
				$pkgver.LICENSE::https://raw.githubusercontent.com/$_repo/$pkgver/LICENSE"
options="!check"


package() {
	install -Dm644 "$srcdir/$pkgver.geoip-cn.db" "$pkgdir/usr/share/$pkgname/geoip-cn.db"
	install -Dm644 "$srcdir/$pkgver.geoip.db"    "$pkgdir/usr/share/$pkgname/geoip.db"
	install -Dm644 "$srcdir/$pkgver.LICENSE"     "$pkgdir/usr/share/licenses/$pkgname/LICENSE"
}

sha512sums="
b6c829b4138119c2d8d2ae3745473ce74e09cd1a7fadfabb5da3e4ebd0622bcb318e79399f73515f6065233f4e03b245de156b59949cf1ee20376a6ddca0b312  20240912.geoip-cn.db
e9c7d9648a976636e46f97fa1386012ac0d127bb1bab07ac6ddb0137474d7245442d9eec1dae47f69f30d1ce8085ce21ab1ccdea1cb11cfbb967383a9d159036  20240912.geoip.db
5cab2697882973e38835376b3e5f45f5720da2a5d408c442ab8c03b97b2cb69387fe5dd7f00e8d3e7dbc9e34797c120c0444b9abb60aba1728e6661970a12418  20240912.LICENSE
"
